<div class="col-md-2">
  <div class="panel panel-default">
    <div class="panel-heading">
      <div class="panel-title">Archives</div>
    </div>
    <div class="panel-body">
      <accordion>
        {% for y, mo in archives.iteritems() %}
        <accordion-group is-open="status.open">
          <accordion-heading>
            {{ y }}
            <i class="pull-right glyphicon" ng-class="{'glyphicon-chevron-down': status.open, 'glyphicon-chevron-right': !status.open}"></i>
          </accordion-heading>
          {% for m, t in mo.iteritems() %}
          <a href='/blog/{{ y }}/{{ m }}/'>{{ monthFullName[m-1] }}</a>
          <span class="badge pull-right">{{ t|length }}</span>
          {% endfor %}
        </accordion-group>
        {% endfor %}
      </accordion>
    </div>
  </div>
  <accordion>
    <accordion-group is-open="status.open">
      <accordion-heading>Tags<i class="pull-right glyphicon" ng-class="{'glyphicon-chevron-down': status.open, 'glyphicon-chevron-right': !status.open}"></i>
      </accordion-heading>
      {% for t, titles in tagstats.iteritems() %}
      <a href="/blog/tag/{{ t|urlencode }}/">{{ t }}</a>
      <span class="badge pull-right">{{ titles|length }}</span>
      {% endfor %}
    </accordion-group>
  </accordion>
</div>
